package com.dyh.quickdemo.quickReturn;

/*
@Author=Joey Wheeler
@Date=2021/3/23 13:08
*/
public class M {



    interface QuickReturnVoid{
        void doReturn();
    }

    interface QuickReturn<T>{
        T doReturn();
    }

    public static long fun1(Integer i1,Long l1,String s1,QuickReturn<Long>... quickReturns){
        if (i1==null)
            return quickReturns[0].doReturn();
        if (l1 == null)
            return quickReturns[1].doReturn();
        return i1+l1+s1.length();
    }

    public static void main(String[] args) {

        Boolean b = false;
        String bs = b.toString();
        System.out.println(b);
        System.out.println(bs);
//        System.out.println(fun1(null,2L,"111",
//                ()->0L)
//        );
    }
}
